package com.example.springboot.listener;

import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

/**
 * refreshContext(context);
 * 从ioc容器中获取所有的ApplicationRunner和CommandLineRunner进行回调
 * ApplicationRunner先回调，CommandLineRunner再回调
 *
 * @Author:ChenZhangKun
 * @Date: 2020/10/14 21:33
 */
@Component
public class MyApplicationRunner implements ApplicationRunner {
    @Override
    public void run(ApplicationArguments args) throws Exception {
        System.out.println("ApplicationRunner...run");
    }
}
